import axios from '@/libs/request/axios'
// 获取退回原因列表
export const getBackPartnersList = (params) => {
    return axios.request({
        url: `/case/loanBackReason/getBackPartnersList`,
        params: params,
        method: 'post'
    })
}

export const getFileTypeList = (params) => {
    return axios.request({
        url: `/case/loanBackReason/getFileTypeList`,
        params: params,
        method: 'post'
    })
}

export const getBackWords = (params) => {
    return axios.request({
        url: `/case/loanBackReason/getBackWords`,
        params: params,
        method: 'post'
    })
}

export const editBackPartner = (params) => {
    return axios.request({
        url: `/case/loanBackReason/editBackPartner`,
        params: params,
        method: 'post'
    })
}

export const saveBackPartner = (params) => {
    return axios.request({
        url: `/case/loanBackReason/saveBackPartner`,
        params: params,
        method: 'post'
    })
}

export const deleteBackPartner = (params) => {
    return axios.request({
        url: `/case/loanBackReason/deleteBackPartner`,
        params: params,
        method: 'post'
    })
}

//  退回经销商
export const submitBackToPartners = (params) => {
    return axios.request({
        url: `/case/loanApprove/submitBackToPartners`,
        params: params,
        method: 'post'
    })
}

//  退回经销商
export const getBackDescList = (data) => {
    return axios.request({
        url: `/case/loanBackReason/getBackDescList`,
        params: {
            data: data,
        },
        method: 'post'
    })
}

//  批量新增或修改退回原因
export const saveOrUpdateBackResonList = (data) => {
    return axios.request({
        url: `/case/loanBackReason/saveOrUpdateBackResonList`,
        data: data,
        method: 'post'
    })
}
